const state = {
  userAvatars: new Map()
}
const mutations = {
  SET_USER: (state, user) => {
    if(user!==null){
      state.userAvatars.set(user.userId,user)
    }
  },
}

const actions = {
  // 设置人员
  setUserAvatars({commit}, data) {
    commit('SET_USER', data)
  }
}

export default {
  namespaced: true,
  state,
  mutations,
  actions
}

